from django.urls import path, re_path
from . import views

app_name = 'verifications'

urlpatterns = [
    # url传递参数 转换器/<int:xx>/
    path('image_codes/<uuid:image_code_id>/', views.ImageCode.as_view(), name='image_code'),
    # re_path正则匹配url中的传递的参数
    re_path('usernames/(?P<username>\w{5,20})/', views.CheckUsernameView.as_view(), name='check_username'),
    # re_path正则匹配url中的传递的参数
    re_path('mobiles/(?P<mobile>1[3-9]\d{9})/', views.CheckMobileView.as_view(), name='check_moblies'),
    # 设置短信验证码的url
    path('sms_codes/', views.SmsCodesView.as_view(), name='sms_codes'),
]
